package com.itheima.collection.traversal;

import java.util.ArrayList;
import java.util.Collection;

/**
 * @author Anomaly
 * @date 2022/12/31 20:45
 */
public class ForeachDemo {
    public static void main(String[] args) {
        Collection<String> collection = new ArrayList<>();

        collection.add("China");
        collection.add("USA");
        collection.add("JAP");

        for (String s : collection) {
            System.out.println(s);
        }
    }
}
